package com.i8office.android.zhihuixinwu.ui.schedule;

import java.io.Serializable;
import java.text.SimpleDateFormat;
import java.util.Calendar;

public class ScheduleTask implements Serializable {

    /**
     * StartTime : 22:40
     * Content : tet1
     * Hour : 10
     * Minute : 40
     * TimeQuantum : 3
     * Location : dsfs1f
     * DeptName : bumen1
     * IsFinished : false
     */

    private String StartTime;
    private String Content;
    private int Hour;
    private int Minute;
    private int TimeQuantum;
    private String Location;
    private String DeptName;
    private boolean IsFinished;
    private String groupTitle;
    private String time12;

    public String getStartTime() {
        return StartTime;
    }

    public String getStartTime12() {
        SimpleDateFormat format = new SimpleDateFormat("hh:mm");
        Calendar calendar = Calendar.getInstance();
        calendar.set(Calendar.HOUR_OF_DAY, Hour);
        calendar.set(Calendar.MINUTE, Minute);
        String tt = "";
        switch (TimeQuantum) {
            case 1:
                tt = "上午\n";
                break;
            case 2:
            case 3:
                tt = "下午\n";
                break;
        }
        if (time12 == null) {
            if ("--:--".equals(StartTime)) {
                time12 = tt + StartTime;
            } else {
                time12 = tt + format.format(calendar.getTimeInMillis());
            }
        }
        return time12;
    }

    public void setStartTime(String StartTime) {
        this.StartTime = StartTime;
    }

    public String getContent() {
        return Content;
    }

    public void setContent(String Content) {
        this.Content = Content;
    }

    public int getHour() {
        return Hour;
    }

    public void setHour(int Hour) {
        this.Hour = Hour;
    }

    public int getMinute() {
        return Minute;
    }

    public void setMinute(int Minute) {
        this.Minute = Minute;
    }

    public int getTimeQuantum() {
        return TimeQuantum;
    }

    public void setTimeQuantum(int TimeQuantum) {
        this.TimeQuantum = TimeQuantum;
    }

    public String getLocation() {
        return Location;
    }

    public void setLocation(String Location) {
        this.Location = Location;
    }

    public String getDeptName() {
        return DeptName;
    }

    public void setDeptName(String DeptName) {
        this.DeptName = DeptName;
    }

    public boolean isIsFinished() {
        return IsFinished;
    }

    public void setIsFinished(boolean IsFinished) {
        this.IsFinished = IsFinished;
    }

    public String getGroupTitle() {
        return groupTitle;
    }

    public void setGroupTitle(String groupTitle) {
        this.groupTitle = groupTitle;
    }

}
